package map;

import java.util.HashMap;
import java.util.Map;
import java.util.Set;

public class Demo3 {
    public static void main(String[] args) {
        Map<String,String>map = new HashMap<>();
        map.put("1号老公","1号妻");
        map.put("2号老公","2号妻");
        map.put("3号老公","3号妻");
        map.put("4号老公","4号妻");
        map.put("5号老公","5号妻");
        Set<String> keys = map.keySet();
        for (String key : keys) {
            String value = map.get(key);
            System.out.println(key+"----"+value);
        }
    }
}
